package com.googlecode.mailnet.math.distribution;

public class DistributionFormatException extends Exception {
    private final String expression;
    private final int position;
    private final String errorDetails;

	public DistributionFormatException(String expression, int position, String errorDetails) {
        super("Couldn't parse expression \"" + expression + "\"; error at position " + position + ": " + errorDetails);
		this.expression = expression;
        this.position = position;
        this.errorDetails = errorDetails;
	}

    public String getExpression() {
        return expression;
    }

    public int getPosition() {
        return position;
    }

    public String getErrorDetails() {
        return errorDetails;
    }
}
